package com.wuster.entity;


import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;


@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class OrderListVO {

    //订单id
    private Long id;
    //订单编号
    private String orderNumber;
    //下单时间
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;
    //订单状态
    private Integer state;
    //用户id
    private Long userId;
    //用户姓名
    private String name;
    //用户电话
    private String phone;
    //收货地址
    private String address;
    //商品id
    private Long productId;
    //预览图片地址
    private String image;
    //商品标题
    private String productName;
    //商品价格
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "0.00")
    private BigDecimal price;
    //商品重量
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "0.00")
    private BigDecimal weight;


}
